<table class="table is-fullwidth is-hoverable is-narrow is-size-7">
  <tbody>
    <% @data.each do |e| %>
      <tr>
        <% if e["group"] == 'db' %>
          <td class="nowrap has-text-right <%= duraction_alert_class(e['duration']) %>">
            <%= e["duration"] %> ms
          </td>
          <td>
            <%= e["sql"] %>
          </td>
        <% elsif e["group"] == 'view' %>
          <td class="nowrap has-text-right <%= duraction_alert_class(extract_duration(e['message'])) %>">
            <%= extract_duration(e["message"]) %>
          </td>
          <td>
            <%= e["message"] %>
          </td>
        <% end %>
      </tr>
    <% end %>

    <% if @data.empty? %>
      <tr>
        <td>Nothing to show here. Perphaps details about the requests already expired. Setting "slow_requests_time_window" should be equal to "duration".</td>
      </td>
    <% end %>
  </tbody>
</table>
